Skip to content

Conversation

@slivingston
Copy link
Member

Implemented the method Function.count() in the Sylvan interface.

Following earlier discussion, this leaves open the question of how many ways to have for performing an operation. Nonetheless, I think adding count() is motivated here because

  1. this makes dd.sylvan support a method already supported by the CUDD and autoref implementations, and
  2. the documentation (doc.md) has an example calling count() in this way since at least 3 years ago, so we might imagine there is code in the wild that follows the pattern.

I did not expose nvars as a parameter for the same reason it was not included in dd.sylvan.BDD.count(). The usefulness is not clear to me, so I suggest that we wait until a user asks for it.

@johnyf johnyf added the enhancement A new feature, an improvement, or other addition. label Aug 15, 2025
@johnyf johnyf merged commit da93635 into main Aug 15, 2025
6 checks passed
@johnyf
Copy link
Member

johnyf commented Aug 15, 2025

Thanks for the addition. I agree with the reasoning.

@johnyf johnyf deleted the sylvan-function-count branch September 8, 2025 08:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement A new feature, an improvement, or other addition.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants